import dpr from './dpr';
export function setSize() {
  const documentElement = document.documentElement

  function callback() {
    let clientWidth = documentElement.clientWidth
    documentElement.style.fontSize = (clientWidth / 375 * 10).toFixed(2) + 'px'
    documentElement.setAttribute("data-dpr", dpr)
  }
  document.addEventListener('DOMContentLoaded', callback)
  window.addEventListener('orientationchange' in window ? 'orientationchange' : 'resize', callback)
}
